package com.me.myFramework.myRPC1;

import org.apache.commons.lang3.RandomStringUtils;

/**
 * 
 *
 * @author ME
 * @date   2020/2/24
 */
public class HelloServiceImpl implements HelloService {

    @Override
    public String hello(String name) {
        String result = "Hello " + name;
        System.out.println(result);
        return result;
    }

    @Override
    public String hello2(String name) {
        System.out.println("方法执行出错：" + name);
        if (1 == 1) {
            throw new RuntimeException(RandomStringUtils.random(10, true, false));
        }

        return "result";
    }

    @Override
    public String hello3(String name) {
        String result = "333 " + name;
        System.out.println(result);
        return result;
    }
}
